package com.ruoyi.ams.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.ams.domain.AmsAssetRepairRecord;
import com.ruoyi.ams.mapper.AmsAssetRepairRecordMapper;
import com.ruoyi.ams.service.IAmsAssetRepairRecordService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 维修信息登记Service业务层处理
 * 
 * @author yfkj
 * @date 2022-05-16
 */
@Service
public class AmsAssetRepairRecordServiceImpl extends ServiceImpl<AmsAssetRepairRecordMapper, AmsAssetRepairRecord>  implements IAmsAssetRepairRecordService
{
    @Autowired
    private AmsAssetRepairRecordMapper amsAssetRepairRecordMapper;

    /**
     * 查询维修信息登记
     * 
     * @param repairRecordId 维修信息登记主键
     * @return 维修信息登记
     */
    @Override
    public AmsAssetRepairRecord selectAmsAssetRepairRecordByRepairRecordId(Long repairRecordId)
    {
        return amsAssetRepairRecordMapper.selectAmsAssetRepairRecordByRepairRecordId(repairRecordId);
    }

    /**
     * 查询维修信息登记列表
     * 
     * @param amsAssetRepairRecord 维修信息登记
     * @return 维修信息登记
     */
    @Override
    public List<AmsAssetRepairRecord> selectAmsAssetRepairRecordList(AmsAssetRepairRecord amsAssetRepairRecord)
    {
        return amsAssetRepairRecordMapper.selectAmsAssetRepairRecordList(amsAssetRepairRecord);
    }

    /**
     * 新增维修信息登记
     * 
     * @param amsAssetRepairRecord 维修信息登记
     * @return 结果
     */
    @Override
    public int insertAmsAssetRepairRecord(AmsAssetRepairRecord amsAssetRepairRecord)
    {
        return amsAssetRepairRecordMapper.insertAmsAssetRepairRecord(amsAssetRepairRecord);
    }

    /**
     * 修改维修信息登记
     * 
     * @param amsAssetRepairRecord 维修信息登记
     * @return 结果
     */
    @Override
    public int updateAmsAssetRepairRecord(AmsAssetRepairRecord amsAssetRepairRecord)
    {
        return amsAssetRepairRecordMapper.updateAmsAssetRepairRecord(amsAssetRepairRecord);
    }

    /**
     * 批量删除维修信息登记
     * 
     * @param repairRecordIds 需要删除的维修信息登记主键
     * @return 结果
     */
    @Override
    public int deleteAmsAssetRepairRecordByRepairRecordIds(Long[] repairRecordIds)
    {
        return amsAssetRepairRecordMapper.deleteAmsAssetRepairRecordByRepairRecordIds(repairRecordIds);
    }

    /**
     * 删除维修信息登记信息
     * 
     * @param repairRecordId 维修信息登记主键
     * @return 结果
     */
    @Override
    public int deleteAmsAssetRepairRecordByRepairRecordId(Long repairRecordId)
    {
        return amsAssetRepairRecordMapper.deleteAmsAssetRepairRecordByRepairRecordId(repairRecordId);
    }
}
